/**
 * Created by xukj on 2018/5/31.
 */

import React from 'react';
import { View, Text } from 'react-native';

export default class MainPage extends React.Component {
  static navigationOptions = ({navigation}) => {
    return (
      {
        headerTitle: '首页',
        tabBarLabel: '首页',
      }
    );
  };

  constructor(props) {
    super(props);
  }

  componentWillMount() {
    console.log('componentWillMount');
  }

  componentDidMount(){
    console.log('componentDidMount');
  }

  componentDidUpdate() {
    console.log('componentDidUpdate');
  }

  componentWillReceiveProps() {
    console.log('componentWillReceiveProps');
  }

  render() {
    console.log('render');
    return (
      <View style={{flex: 1, justifyContent: 'center', alignItems: 'center'}}>
        <Text>首页</Text>
      </View>
    );
  }
}